s = {1,2,3,4}

ss = set('1234')
print(type(s))
print(type(ss))


#集合的添加和删除
# 添加元素
s.add(6)
print(s)

#删除集合中第一个元素
s.pop()
print(s)

# 删除集合中的元素
s.remove(4)
print(s)


# #创建元组
#创建空元组
tuple1 = ()
print(tuple1)

tuple2 =(1,"a",3,"helle",2.2)
print(tuple2)

tuple3=(1,)
print(type(tuple3))



tuple1 = tuple('hello,world')
print(tuple1)

list1 =['Python','Java,''c++,''c']
tuple2 =tuple(list1)
print(tuple2)



tuple1 = ('h','e','l','l','o')

print(tuple1[2])

print(tuple1[-4])


print(tuple1[1:4])

print(tuple1[1:4:2])

print(tuple1[-5:-1])
